package com.scs.application.modules.wm.service;

import com.scs.application.core.flow.FlowContext;
import com.scs.application.core.service.IBaseService;
import com.scs.application.modules.sys.entity.FlowButton;
import com.scs.application.modules.wm.dto.AdjustLocationDTO;
import com.scs.application.modules.wm.entity.Transfer;
import com.scs.application.modules.wm.entity.TransferItem;
import com.scs.application.modules.wm.entity.WorkOrder;
import com.scs.application.modules.wm.vo.TransferVO;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * Service
 * </p>
 */

public interface TransferService extends IBaseService<Transfer> {
    /**
     * 自动转调拨单（由入库单）
     * @param workOrder
     * @return
     */
    Transfer autoChangeTransfer(WorkOrder workOrder);
    /**
    * @Description：调拨单进行出入库
     * @param isUnlock true:解锁
    */
    void autoOutIn(Transfer transfer,boolean isUnlock);

    void autoOutInForFsd(Transfer transfer);

    TransferVO findByIdForPDA(String key, String value);

    /**
     * 查询所有非审核通过的配送单
     */
    List<Map> findAllList(String busKey);

    Boolean pickFinishedPDA(String id);

    /**
     * 货位调整
     * @param adjustLocationDTO
     * @return
     */
    String adjustLocation(AdjustLocationDTO adjustLocationDTO);

    String adjustLocationByType(AdjustLocationDTO adjustLocationDTO);
    /**
     * 根据busKey获取调拨单
     * @param busKey
     * @return
     */
    Map<String, Object> getByBusKey(String busKey);

    void doOne(FlowContext flowContext,FlowButton flowButton, Transfer transfer, List<TransferItem> transferItemList);
}
